﻿using System.Collections.Generic;
using System.Web.Mvc;
using DevTrends.MvcDonutCaching;
using KMF.Common;
using KMF.DAL;


namespace KMF.WebUI.Controllers
{
    public class BannerController : Controller
    {
        //
        // GET: /Banner/

        #region Trang chu

        //[DonutOutputCache(CacheProfile = "OneDay")]
        public PartialViewResult BannerOnHeader()
        {
            var model = BannerDb.GetAllBanner() ?? new List<ViewBannerClientDto>();
            return PartialView(model);
        }

        //[DonutOutputCache(CacheProfile = "OneDay")]
        public PartialViewResult BannerSlideOnHome()
        {
            var model = BannerDb.GetAllBanner() ?? new List<ViewBannerClientDto>();
            return PartialView(model);
        }

        //[DonutOutputCache(CacheProfile = "OneDay")]
        public PartialViewResult BannerRightTopOnHome()
        {
            var model = BannerDb.GetAllBanner() ?? new List<ViewBannerClientDto>();
            return PartialView(model);
        }

        //[DonutOutputCache(CacheProfile = "OneDay")]
        public PartialViewResult BannerBottomSlideOnHome()
        {
            var model = BannerDb.GetAllBanner() ?? new List<ViewBannerClientDto>();
            return PartialView(model);
        }

        //[DonutOutputCache(CacheProfile = "OneDay")]
        public PartialViewResult BannerHomeCenter()
        {
            var model = BannerDb.GetAllBanner() ?? new List<ViewBannerClientDto>();
            return PartialView(model);
        }
        #endregion

    }
}
